var ws, aid;
document.addEventListener('plusready', function(){
	ws = plus.webview.currentWebview();
	aid = ws.aid;
	console.log(aid);
	showWating();
	$.ajax({
		type:"get",
		url:apiRoot+"/home/bespoke/bookInfo",
		data:{aid:aid},
		dataType :'json',
		success :function(data){
			plus.nativeUI.closeWaiting();
//			console.log(JSON.stringify(data));
			var Array = [data.timeslot, data.offices, data.doctor, data.level];
			$('.div-first p').each(function(k){
				$(this).find('span').eq(1).text(Array[k]);
			})
			var Array1 = [data.name, data.sex, data.age, data.idcard, data.weight, data.height, data.phone, data.address];
			$('.mui-input-group li').each(function(k){
				$(this).find('span').eq(1).text(Array1[k]);
			})
			var Array2 = [data.rmoney, data.imoney, data.total];
			$('ul').eq(1).find('li').each(function(k){
				$(this).find('span').eq(1).text('¥'+Array2[k]);
			})
		},
		error :function(e){
			console.log(JSON.stringify(e));
			errortoast();
		}
	});
}, false)